package com.warom.sdg.model;

/**
 * 虫情检测数据实体类
 */
public class PestDetectionEntity {
    private int id;
    private int deviceId;
    private String pestType;
    private double confidence;
    private int count;
    private String imageUrl;
    private long timestamp;
    private String status;

    // 无参构造函数
    public PestDetectionEntity() {
    }

    /**
     * 构造函数
     * 
     * @param id         ID
     * @param deviceId   设备ID
     * @param pestType   害虫类型
     * @param confidence 置信度
     * @param count      数量
     * @param imageUrl   图片URL
     * @param timestamp  时间戳
     * @param status     状态
     */
    public PestDetectionEntity(int id, int deviceId, String pestType, double confidence, int count, 
                             String imageUrl, long timestamp, String status) {
        this.id = id;
        this.deviceId = deviceId;
        this.pestType = pestType;
        this.confidence = confidence;
        this.count = count;
        this.imageUrl = imageUrl;
        this.timestamp = timestamp;
        this.status = status;
    }

    // Getter和Setter方法
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getDeviceId() {
        return deviceId;
    }

    public void setDeviceId(int deviceId) {
        this.deviceId = deviceId;
    }

    public String getPestType() {
        return pestType;
    }

    public void setPestType(String pestType) {
        this.pestType = pestType;
    }

    public double getConfidence() {
        return confidence;
    }

    public void setConfidence(double confidence) {
        this.confidence = confidence;
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public String getImageUrl() {
        return imageUrl;
    }

    public void setImageUrl(String imageUrl) {
        this.imageUrl = imageUrl;
    }

    public long getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(long timestamp) {
        this.timestamp = timestamp;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    @Override
    public String toString() {
        return "PestDetectionEntity{" +
                "id=" + id +
                ", deviceId=" + deviceId +
                ", pestType='" + pestType + '\'' +
                ", confidence=" + confidence +
                ", count=" + count +
                ", imageUrl='" + imageUrl + '\'' +
                ", timestamp=" + timestamp +
                ", status='" + status + '\'' +
                '}';
    }
} 